package com.xigua.chapter_3_template.example;

/**
 * @author LiRongHua
 * @Title: ${file_name}
 * @Package ${package_name}
 * @Description: ${todo}
 * @date 2022/3/2922:35
 */
public class StrDisplay extends AbstractDisplay {

    private String string;

    public StrDisplay(String string) {
        this.string = string;
    }

    public void open() {
        System.out.print("+-----------------+");
    }

    public void print() {
        System.out.println("|"+string+"|");
    }

    public void close() {
        System.out.print("+-----------------+");
    }
}
